package com.education.online.service.impl;

import com.education.common.utils.Convert;
import com.education.online.mapper.OMsgMapper;
import com.education.online.pojo.OMsg;
import com.education.online.service.OMsgService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import java.util.List;

/**
 * 消息表 服务层实现
 *
 * @author d
 * @date 2020-06-28 17:01:13
 */
@Service
public class OMsgServiceImpl implements OMsgService {

    @Autowired
    private OMsgMapper oMsgMapper;

    //查询消息表信息
    @Override
    public OMsg selectOMsgById(Integer id) {
        return oMsgMapper.selectOMsgById(id);
    }

    // 查询消息表列表
    @Override
    public List<OMsg> selectOMsgList(OMsg oMsg) {
        return oMsgMapper.selectOMsgList(oMsg);
    }

    // 新增消息表
    @Override
    public int insertOMsg(OMsg oMsg) {
        return oMsgMapper.insertOMsg(oMsg);
    }

    //修改消息表
    @Override
    public int updateOMsg(OMsg oMsg) {
        return oMsgMapper.updateOMsg(oMsg);
    }

    //删除消息表对象
    @Override
    public int deleteOMsgByIds(String ids) {
        return oMsgMapper.deleteOMsgByIds(Convert.toStrArray(ids));
    }
}